<template>
 <div >111111111</div>
 <childr :num="num"  @changeData="fn"></childr>
</template>

<script setup>
import { ref,onMounted,provide } from "vue";
import childr from './components/childr.vue'
const num=ref(100)

const fn=(val)=>{
  console.log(val)
}
const myData=ref(false)
provide('myData',myData)

const chengeaaa=(val)=>{
  myData.value=val
}
provide('chengeaaa',chengeaaa)

</script>
